package com.ydzh.kfqgwvisitor.controller;


import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import com.ydzh.kfqgwvisitor.base.Result;
import com.ydzh.kfqgwvisitor.entity.BeUnit;
import com.ydzh.kfqgwvisitor.service.BeUnitService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 被访人单位信息表  前端控制器
 * </p>
 *
 * @author zcj
 * @since 2021-09-01
 */
@RestController
@RequestMapping("/beUnit")
@Api(tags = "单位")
public class BeUnitController {

    @Autowired
    private BeUnitService beUnitService;


    @ApiOperation(value = "单位集合")
    @ApiOperationSupport(order = 1)
    @GetMapping("/unitList")
    public Result<BeUnit> unitList() {
        return Result.buildSuccess(beUnitService.list());
    }


}

